public class Pet {
	String name;
	public  void eat() {
		System.out.println("这是我的父类宠物在吃东西");
	}
	public void testFather() {
		System.out.println("测试父类的方法");
	}
}
class Cat extends Pet{
	String name;

	public Cat(String name) {
		this.name = name;
	}

	@Override
	public void eat() {
		System.out.println(this.name+"在吃鱼");
	}
	public void lookDoor() {
		System.out.println(this.name+"在看大门");
	}
}
class Dog extends Pet{
	String name;

	public Dog(String name) {
		this.name = name;
	}

	@Override
	public void eat() {
		System.out.println(this.name+"在啃骨头");
	}
	public void catchMouse() {
		System.out.println(this.name+"在抓老鼠");
	}
}
